$(document).ready(function (){
    $('.layerenter-head-tab-l').click(function (){
        $('.layerenter-head-tab span').removeClass('layer-active');
        $(this).addClass('layer-active');
        $('#register').css('display','none');
        $('#login').css('display','block');    
    });
    $('.layerenter-head-tab-r').click(function (){
        $('.layerenter-head-tab span').removeClass('layer-active');
        $(this).addClass('layer-active');
        $('#login').css('display','none');
        $('#register').css('display','block');
    });
});